<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
 <head>
    <meta http-equiv="Content-Type" content="text/html; charset=utf-8">
    <title>Flot Examples</title>
	<!--<link href="layout.css" rel="stylesheet" type="text/css">-->
    <!--[if lte IE 8]><script language="javascript" type="text/javascript" src="../excanvas.min.js"></script><![endif]-->
    <script language="javascript" type="text/javascript" src="http://people.iola.dk/olau/flot/jquery.js"></script>
    <script language="javascript" type="text/javascript" src="http://people.iola.dk/olau/flot/jquery.flot.js"></script>
 </head>
    <body>
    <h1>Flot Examples</h1>
	{% for graph in graphs %}
		<h1>{{ graph.name }}</h1>
	    <p>{{ graph.description }}</h1>
		<div id="graph_id_{{ graph.id }}" style="width:600px;height:300px;"></div>
	{% empty %}
	    <li>No Graphs defined in report</li>
	{% endfor %}

	
<script type="text/javascript">
$(function () {
		var gids=[];
		{% for graph in graphs %}
			gids.push({{ graph.id }});
		{% endfor %}
	for (id in gids){
		$.getJSON('/graph/' + gids[id], function(data) {
			//render the graph
			$.plot($(data.placeholder),data.series,data.options)
		});
	}
});



</script>

 </body>
</html>
